package domainmodel;

import java.util.ArrayList;

public class TekenBlad {
	ArrayList<Figuur> figuren;
	
	public TekenBlad()
	{
		figuren = new ArrayList<Figuur>();
	}
	
	public boolean addPicture(Figuur picture) throws IllegalArgumentException
	{
		if (picture == null)
			throw new IllegalArgumentException("picture is null");
		
		return figuren.add(picture);
	}
	
	public boolean removePicture(Figuur picture) throws IllegalArgumentException
	{
		if (picture == null)
			throw new IllegalArgumentException("picture is null");
		
		return figuren.remove(picture);		
	}
	
	public String toString()
	{
		String resultaat = "";
		for (Figuur fig : figuren)
		{
			resultaat += " " + fig.toString();
		}
		return resultaat;
	}
	
	
	
}
